<script setup>
import {nextTick, provide, ref} from "vue";
import {ElConfigProvider} from "element-plus";
// 局部组件刷新
const isRouterAlive = ref(true);
const reload = () => {
  isRouterAlive.value = false;
  nextTick(() => {
    isRouterAlive.value = true;
  });
};
provide("reload", reload);
</script>

<template>
  <ElConfigProvider>
    <router-view v-if="isRouterAlive">
    </router-view>
  </ElConfigProvider>
</template>

<style scoped>
</style>
